﻿
@model HttpRequestBase


Get:
<form method="get" action="/Home/TestFormGet">
    <input type="text" name="text1" />
    <input type="hidden" name="hidden1" value="hiddenValue1" />
    <div>
        <textarea name="textarea1"></textarea>
    </div>

    <input type="submit" name="submit1" value="Submit!" />
    <button type="submit" name="buttonSubmit1" value="Button Submit">Submit button</button>
</form>


Post:
<form method="post" action="/Home/TestFormGet">
    <input type="text" name="text1" />
    <input type="hidden" name="hidden1" value="hiddenValue1" />
    <div>
        <textarea name="textarea1"></textarea>
    </div>

    <input type="submit" name="submit1" value="Submit!" />
    <button type="submit" name="buttonSubmit1" value="Button Submit">Submit button</button>
</form>

@if(Model!=null) {

<table>
    <tr><th>Method</th><td>@Model.HttpMethod</td></tr>
    <tr><th>Data</th><td>

    Query string:
    <table>
    <tr><th>Name</th><th>Value</th></tr>
        @foreach (string key in Model.QueryString)
        {
             <tr><td>@key</td><td>@Model.QueryString[key]</td></tr>

        }
    </table>

    Form:
    <table>
    <tr><th>Name</th><th>Value</th></tr>
        @foreach (string key in Model.Form)
        {
             <tr><td>@key</td><td>@Model.Form[key]</td></tr>

        }
    </table>

  </td></tr>


</table>


}


